<?php


namespace app\article\controller;


use app\common\cachemodel\ZlcrSlide;
use think\Controller;

class ZlcrSlideController extends Controller
{
    public function detail()
    {
        $id = input('param.id/d', 0);

        $slides = (new ZlcrSlide())->getSlideList();
        $data = null;
        foreach ($slides as $v)
        {
            if ($id === (int)$v['id'])
            {
                $data = $v;
            }
        }

        if (!$id || !$data) exit('内容不存在！');

        return $this->fetch('astrologer_slide/index', ['data' => $data]);
    }

}
